﻿<controls:ChildWindow xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:controls="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk" mc:Ignorable="d" x:Class="HelloWorld.View.OrderDetailView" Width="400" Height="300" Title="OrderDetailView">
	<Grid x:Name="LayoutRoot" Margin="2" d:DataContext="{Binding OrderDetailViewModel, Source={StaticResource ViewModelLocator}}">
		<Grid.RowDefinitions>
			<RowDefinition />
			<RowDefinition Height="Auto" />
		</Grid.RowDefinitions>

		<Button x:Name="Cancel" Content="Cancel" Width="75" Height="23" HorizontalAlignment="Right" Margin="0,12,0,0" Grid.Row="1" />
		<Button x:Name="Ok" Content="OK" Width="75" Height="23" HorizontalAlignment="Right" Margin="0,12,79,0" Grid.Row="1" />
		<sdk:Label HorizontalAlignment="Left" Height="16" Margin="18,46,0,0" VerticalAlignment="Top" Width="103" Content="Ship Name" />
		<TextBox Height="20" Margin="162,42,17,0" TextWrapping="Wrap" Text="{Binding CurrentOrder.ShipName, Mode=TwoWay}" VerticalAlignment="Top" />
		<sdk:Label HorizontalAlignment="Left" Height="18" Margin="18,78,0,0" VerticalAlignment="Top" Width="136" Content="Ship Address" />
		<sdk:Label HorizontalAlignment="Left" Margin="18,110,0,95" Width="137" Content="Ship City" />
		<TextBox Height="20" Margin="162,76,17,0" TextWrapping="Wrap" Text="{Binding CurrentOrder.ShipAddress, Mode=TwoWay}" VerticalAlignment="Top" />
		<TextBox Height="20" Margin="162,110,17,96" TextWrapping="Wrap" Text="{Binding CurrentOrder.ShipCity, Mode=TwoWay}" />
		<TextBox Height="20" Margin="162,0,17,62" TextWrapping="Wrap" Text="{Binding CurrentOrder.ShipPostalCode, Mode=TwoWay}" VerticalAlignment="Bottom" />
		<sdk:Label HorizontalAlignment="Left" Height="20" Margin="18,0,0,62" VerticalAlignment="Bottom" Width="117" Content="Ship Postal Code" />
		<sdk:Label HorizontalAlignment="Left" Height="20" Margin="18,8,0,0" VerticalAlignment="Top" Width="61" Content="Order ID" />
		<TextBlock Height="19" Margin="160,9,17,0" TextWrapping="Wrap" Text="{Binding CurrentOrder.OrderID}" VerticalAlignment="Top" />
        <ListBox Height="49" HorizontalAlignment="Left" Margin="18,176,0,0" VerticalAlignment="Top" Width="345" ItemsSource="{Binding ErrorHandler.ErrorMessages}" Foreground="Red" Background="#FFF2F4F6" />
    </Grid>
</controls:ChildWindow>